<div class="account-menu-wrap">
    <div class="account-menu-cont">
        <ul>
            <li><a href="${path}/member/">账户总览</a></li>
            <li><a href="${path}/member/deal/tender">我的投资</a></li>
            <li class="active"><a href="${path}/member/deal/loan">我的借款</a></li>
            <li><a href="${path}/member/ucenter/safe">账户设置</a></li>
            <li><a href="${path}/member/account/recharges">充值提现</i></a></li>

            <li><a href="${path}/member/ucenter/gokefu">我的客服</a></li>
            <li><a href="${path}/member/promotion/link">我的邀请</a></li>
        </ul>
    </div>
</div>

<link href="${path}/resources/plug/layui/css/layui.css" rel="stylesheet" type="text/css"/>
<script src="${path}/resources/plug/layui/layui.js" type="text/javascript"></script>
<script>
    $(function(){
        //会员中心菜单
        function showSelectedMenu(){
            var menu = layui.data('menu');
            if(menu){
                $(".account-menu-cont>ul>li").each(function(index){
                    if(menu.m_menu-1 == index){
                        $(this).addClass("active");
                    }else{
                        $(this).removeClass("active")
                    }
                });
            }
        }

        showSelectedMenu();

        $(".account-menu-cont>ul>li").click(function(){
            var index = $(this).index();
            layui.data("menu", {
                key: 'm_menu'
                ,value: index+1
            });
        });

        $(".account-menu-cont a").click(function(){
            $(this).parent().click();
            showSelectedMenu();
        });
    });
</script>


